# def fun(x,y):
#     global bool
#     b = 3
#     c = a + b
#     return c
# a = 1
# b = 2
# c = fun(a,b)
# print(a,b,c)

def outer():
    a = 1
    def inner():
        nonlocal a
        a = 2
    print(a)
outer()